-- GENERATED SPELL FOR [Bloodwarder Vindicator] --


function spell0_20032(pUnit, Event) --@Cleanse,n/a--
pUnit:FullCastSpellOnTarget(39078,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_20032', 577, 1)
end

function spell1_20032(pUnit, Event) --@Flash of Light,Heal--
pUnit:FullCastSpellOnTarget(37249,pUnit)
pUnit:RegisterEvent('Sorts_20032', 1500, 1)
end

function spell2_20032(pUnit, Event) --@Hammer of Justice,n/a--
pUnit:FullCastSpellOnTarget(13005,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_20032', 6320, 1)
end

function spell3_20032(pUnit, Event) --@Hammer of Wrath,n/a--
pUnit:FullCastSpellOnTarget(37251,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_20032', 500, 1)
end

function Sorts_20032(pUnit, Event)
local choix_sorts_20032 = math.random(0, 3)
if choix_sorts_20032 == 0 then
pUnit:RegisterEvent('spell0_20032', 1, 1)
end
if choix_sorts_20032 == 1 then
pUnit:RegisterEvent('spell1_20032', 1, 1)
end
if choix_sorts_20032 == 2 then
pUnit:RegisterEvent('spell2_20032', 1, 1)
end
if choix_sorts_20032 == 3 then
pUnit:RegisterEvent('spell3_20032', 1, 1)
end
end

function mob20032_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_20032', math.random(1500, 3000), 1)
end

function mob20032_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob20032_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob20032_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(20032, 1, 'mob20032_Action')
RegisterUnitEvent(20032, 2, 'mob20032_Leave')
RegisterUnitEvent(20032, 3, 'mob20032_Kill')
RegisterUnitEvent(20032, 4, 'mob20032_Die')
